obj2=sum.o sub.o

libmymath.so:$(obj2)
	g++ -fPIC -shared $^ -o $@
	g++ -c $<
%.o:./dynamic_lib_src/%.cc
	g++ -c $<

.PHONY:clean
clean:
	rm -f *.o test
	rm -f libmymath.so
.PHONY:output
output:
	rm -rf dynamic_lib_output
	mkdir dynamic_lib_output
	cp -rf ./dynamic_lib_src/*.h dynamic_lib_output 
	cp libmymath.so dynamic_lib_output
	rm -f libmymath.so
.PHONY:create
create:
	g++ test.cc -I./dynamic_lib_output -L./dynamic_lib_output -lmymath -o test -std=c++11
